<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<div id="example-2">
		  <!-- `greet` 是在下面定义的方法名 -->
		  <button v-on:click="greet($event,1)">Greet</button>
		</div>
	</body>
	<script src="../vue.js" type="text/javascript" charset="utf-8"></script>
	
	<script type="text/javascript">
		
		var example2 = new Vue({
		  el: '#example-2',
		  data: {
		    name: 'Vue.js'
		  },
		  // 在 `methods` 对象中定义方法
		  methods: {
		    greet: function (event,value) {
				
		      console.log(event);
			  console.log(value);
		    }
		  }
		})
	</script>
</html>
